package com.szxy.service.feign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * @Author: zwz
 * @Date:2020/7/16 15:40
 * @Description:com.szxy.service.feign
 * @Version:1.0
 **/
@FeignClient("account-service")
public interface AccountServiceFeign {

    /**
     *  从用户账户中扣减金额
     * @return ResponseEntity
     */
    @GetMapping("deBin/{userId}/{money}")
    public ResponseEntity<Void> deBin(
            @PathVariable("userId") String userId,
            @PathVariable("money") int money
    );

}
